home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Trusted Irix /B 4.0.4
/
Trusted-Irix B-4.0.1.iso
/
dist
/
eoe1.idb
/
usr
/
include
/
sys
/
fs
/
pipe_inode.h.z
/
pipe_inode.h
Wrap
C/C++ Source or Header
|
1992-04-03
|
1KB
|
50 lines
/*
* Definitions for "pipe" filesystem.
*
* $Source: /src_trees/calypso/att/usr/src/uts/mips/sys/fs/RCS/pipe_inode.h,v $
* $Date: 89/11/28 14:38:48 $
* $Revision: 3.6 $
*/
#include "sys/fs/com_inode.h"
#include "sys/poll.h"
#include "sys/sema.h"
/*
* Common inode information for named pipes under the efs. The
* implementation for pipes and fifos is shared by all the disk
* file systems (EFS and S5).
*/
struct pipe_inode {
struct com_inode pi_com;
ushort pi_flags; /* state flags */
short pi_frptr; /* read pointer */
short pi_fwptr; /* write pointer */
sema_t pi_frcnt; /* number of readers count */
sema_t pi_fwcnt; /* number of writers count */
sema_t pi_empty; /* counting sema for waiting cause empty */
sema_t pi_full; /* counting sema for waiting cause full */
struct pollqueue pi_rpq; /* poll/select process queues */
struct pollqueue pi_wpq;
caddr_t pi_bp; /* buffer holding data */
};
#define pipe_fsptr(ip) ((struct pipe_inode *) (ip)->i_fsptr)
#define PIPE_SIZE 10240
#define PIPE_MAGIC 0xF1F0F1F0
/*
* Pipe flags.
*/
#define PIPE_WCLOSED 0x0001 /* last writer has closed */
#ifdef _KERNEL
/*
* Filesystem switch functions (should be void).
*/
extern pipe_openi();
extern pipe_closei();
extern pipe_readi();
extern pipe_writei();
#endif